Auxiliary function command presequencing for a robot controller

ABSTRACT

A control system for a work robot having a number of articulated links including a controller for driving the links under closed loop servo control in response to a sequence of recorded link position commands read from a robot program memory. The sequence of link position commands is produced in a training session by an operator manually manipulating a robot simulator, or training arm, through a series of work-performing motions which are to be duplicated by the work robot. The sequence of link position commands produced by manual manipulation of the training arm during the training session is stored in the robot program memory. When the work robot is subsequently driven under closed loop servo control in response to the program stored in the robot memory, the controller also executes auxiliary functions, such as movement of a work piece operated upon by the work robot, in response to auxiliary function commands which are also stored in the robot program memory. In order to properly store the auxiliary function commands in the robot program memory, the auxiliary function commands are loaded in an auxiliary function memory prior to a training session so that they can be read out in a desired sequence.

DESCRIPTION OF THE INVENTION

This invention relates generally to a control system for a work robotincluding a controller for concurrently driving at least one articulatedrobot link under closed loop servo control and executing at least oneauxiliary function operating in conjunction with the robot link inresponse to a stored sequence of recorded link position commands andauxiliary function commands. The invention is disclosed particularly inrelation to a work robot for spray painting a work piece in which thecontrol system serves to move and operate a paint spray gun on anarticulated robot arm and to control auxiliary functions, not related tothe control of the gun or the arm, such as rotation of the work pieceduring the spray painting operation or the activation of an exhaust fanin the painting area.

A work-performing robot, or manipulator, typically includes a pluralityof links interconnected to provide relative motion with a plurality ofdegrees of freedom. The links are each provided with a signal-controlledactuator for powering the respective links, as well as a positiontransducer for providing a real-time signal correlated to the actualposition of the robot link. In order to provide the actuator controlsignals, a sequence of command positions for each link is stored in asuitable memory device and the command positions are periodicallyretrieved and compared against the actual link position signals providedby the link position transducers. In response to the comparisons, linkpositional error signals are generated for each of the links and theninput to the various link actuators. Therefore, closed loop servotechniques are utilized to drive the various link actuators to move thelinks to the desired command positions.

There are many applications for work robots such as welding and theapplication of various coating materials. As an illustrative example, awork-performing robot may be used for spray painting specific articlesof differing shapes. A program comprising sequences of command positionsfor the robot links is then produced to effect the movement of the robotfor the spraying of paint onto such articles, such program taking intoaccount the specific dimensions and paint requirements of the particulararticle.

A paint spraying robot typically includes a spray painting gun at theoutboard end of the outermost link of a multi-link articulated arm. Thegun is controlled to spray paint an article, or work piece, located at awork station as the robot executes a prerecorded sequence of robot linkposition commands. In order to control the application of paint by thegun, the spray gun includes a number of devices such as an electrode forelectrostatically charging the sprayed paint, a paint flow controlvalve, and fan outlets for applying pressurized air to the paint sprayedfrom the gun.

An electrostatic switch is controlled by programmed commands toselectively apply an electrostatic potential to the electrode, and henceto the paint sprayed by the gun. An OFF/ON/FAN switch is likewisecontrolled by programmed commands to regulate the spraying of paint fromthe gun. The gun is responsive to an OFF command to close the paint flowcontrol valve and to an ON command to open the paint flow control valveto supply paint in a first pattern. In response to a FAN command, theflow control valve is opened and two streams of pressurized air from thefan outlets are applied to the paint as it is sprayed from the gun toshape the sprayed paint into a second pattern. The commands to controlthe flow of paint from the gun and the commands to control theapplication of electrostatic charge to the sprayed paint shall bereferred to herein collectively as "gun commands".

In order to control the movement of the work robot, a sequence ofcommand positions for each robot link is stored in a robot programmemory. The sequences of command positions for the robot links, taken asa whole, constitute a complete program for a particular movementsequence to be performed by the robot. The gun commands are also storedin the robot program memory, in proper timed relationship to the linkposition commands, to be sequentially retrieved from the robot programmemory and output to the spray gun to control the electrostatic chargingdevice and the paint spray devices. Since both the link positioncommands and the gun commands are processed concurrently, the emissionof spray paint is coordinated with the movement of the gun relative tothe work piece.

Production of the prerecorded motion and gun command sequence, known asrobot "training" or "teaching", can be accomplished in several ways. Inone approach, a lightweight "training robot", or simulator, is usedwhich, except for the reduced mass of the training robot and the absenceof actuators for the links, is identical in all respects to theconsiderably more massive work robot which is being programmed. Toprogram the work robot, the output element of the simulator, the spraygun, is grasped manually by the operator doing the programming and movedthrough a sequence of motions which it is desired to have the work robotsubsequently execute. Since the training robot is lightweight, it can bemoved manually by the operator with little difficulty. As the simulatorrobot is moved through the desired sequence of motions, positiontransducers at the joints of its links produce electrical link positionsignals which are recorded for subsequent servo loop control of the workrobot. Simultaneously with the simulator movement, the gun switches(electrostatic and/or OFF/ON/FAN) are manually operated to control theemission of the spray paint from the gun. The conditions of the gunswitches are recorded in synchronism with the recording of the linkposition transducer outputs for subsequent replay by the gun devices andthe work robot, respectively. When the robot program is thereafterreplayed, the recorded sequence of gun commands is output to the spraygun in synchronism with the sequence of robot position commands, therebycoordinating spray coating emission with the spray gun position.

In another method of robot programming, the actuators of the work robotare bypassed or decoupled and the work robot is counterbalanced so thatthe operator may more easily move the work robot through a desired pathduring training. The robot link position transducer outputs are recordedduring this manual programming phase, as are the gun command signals, sothat they can be subsequently replayed for execution by the robot andthe gun, respectively.

Another approach to training a work robot involves providing the workrobot with motion or force-sensing transducers. When an operatorattempts to move the work robot during manual programming, the force ormotion sensors detect the force or motion applied by the operator to therobot. The force or motion sensor outputs are input to the actuators formoving the individual work robot links in accordance with the manualforce or motion applied thereto by the operator. As the robot links moveunder power assistance, the link position transducer outputs arerecorded, along with the gun condition signals, for subsequent replayand execution by the robot and the gun, respectively.

During a robot training or teaching session, such as when using a robotsimulator, the operator of the simulator manually controls the movementof the simulator and the operation of the gun switches. The simulatormotion and the gun switch conditions are recorded to form the programfor the work robot. Typically, the paint spraying simulation executed bythe operator is the actual spray painting of a work piece under the sameconditions as will be encountered by the work robot. Therefore, theoperator not only moves the gun, but also operates the gun switches tocontrol both the spraying of paint in a particular pattern upon a workpiece and the application of electrostatic charge to the paint spray.During the training session, the operator applies paint to the workpiece in a manner to obtain an observably satisfactory coating of painton the work piece.

During a training session, the operator manipulates the simulator robotand the gun to spray paint a work piece at a work site such as in apaint spray booth or along a work piece conveyor line. The link positioncommands and the gun commands from the simulator are coupled from thesimulator and the gun through cables to a robot controller consolelocated some distance from the work site. During a training session, asecond operator at the controller console verbally communicates with thesimulator operator and starts and stops the recording of the paint sprayprogram produced by the simulator. The second operator typicallyinterfaces with the controller through a keyboard and display terminalto properly record the link position commands and gun commands in therobot program memory of the controller.

During a training session, while the simulator operator moves the gun,and controls the gun switches, often there are other functions whichmust be performed in regard to the gun, the work piece or theenvironment in order to produce a complete spray painting program. Forexample, in the course of painting a work piece, it may be necessary tochange the color of the paint being applied. To do this, a command mustbe issued to the paint source to effect the change in the color of paintwhich is supplied to the spray gun.

As another example, if it is necessary to paint two sides of a workpiece, a command may be issued to a servo motor for a work piece holderto turn the work piece so that the second side of the work piece isaccessible to the operator of the simulator. If the work site is anenclosed paint spray booth, it may be necessary to issue a command toactivate an exhaust fan at the beginning of a spray painting operationand another command to deactivate the fan at the end.

During a training session, the commands for these functions are producedby the second operator at the controller console. These commands areboth executed during the training session, so that a proper program canbe prepared by the simulator operator, and recorded with the linkposition commands and the gun commands, in proper timed relationshipthereto, to produce a complete spray painting program for the workrobot.

As an example of the implementation of such functions during a trainingsession, if the work piece is a relatively flat panel having two sideswhich are to be painted, a command must be produced to effect turningthe panel during the training session. In addition, a command must alsobe recorded, at the proper time, in the program stored in the robotprogram memory so that the panel will be turned at the proper timeduring subsequent execution of the program by the work robot. In orderto produce the proper command during training, typically the operator ofthe simulator robot verbally communicates with the second operator atthe console at the time that the simulator operator has completedpainting one side of the panel and wishes the panel turned to provideaccess to the other side of the panel.

The second operator at the console responds to the verbal request by thesimulator operator by depressing the appropriate key or combination ofkeys on the console keyboard to produce a command to turn the workpiece. This command is coupled to, for example, a servo motor to rotatethe work piece 180°, and the command is also recorded with the sequenceof link position commands at a point in the sequence correlated with thepoint in the link command sequence at which the "turn part" command isissued at the console.

The above-described commands, related to auxiliary functions such asturning the work piece or activating an exhaust fan, shall be referredto herein as "auxiliary function commands", or "auxiliary commands". Inthe past, the implementation of such auxiliary commands during atraining session has required a second operator, in addition to theoperator of the simulator robot, at the controller console, at alocation remote from the robot work site. The need for an additionaloperator in producing a paint spray program is, of course, costly, andit would be desirable for a single operator to be able to create anentire paint spray program during a training session.

It would appear that the only way to accomplish this would be to move akeyboard or control panel to the work site in order to make itaccessible to the simulator operator. In this way, the operator of thesimulator would be able to key in the desired auxiliary commands in thecourse of moving the spray gun and operating the gun controls during atraining session.

However, if a separate auxiliary control panel is provided, thesimulator operator must divide his attention between manipulating thespray gun to properly paint the work piece and selecting appropriatebuttons or keys to produce a desired auxiliary function command. If theauxiliary function keys are placed upon the spray gun in some fashion, alarge number of auxiliary command signal cables from the keys to therobot controller are required, making movement of the gun difficult.Whatever the location of such an auxiliary keyboard, there would be alarge array of auxiliary function keys, such as ten or twenty, and theburden of selecting the proper key for the desired auxiliary function atthe proper time would prohibit the similator operator from concentratingon proper manipulation of the spray gun and the simulator robot.

It is the general aim of the invention, therefore, to provide a workrobot control system, such as a system for the control of a robot of theforegoing paint spray type, in which a sequence of interleaved linkposition commands, gun commands, and auxiliary function commands areproduced for the work robot by a single operator.

This objective has been accomplished in accordance with certainprinciples of the invention by providing a control system for a workrobot which includes an auxiliary function memory which is loaded, priorto a training session, with auxiliary function commands so that they canbe read from the auxiliary function memory during the training sessionin the sequence in which they are needed. In the illustrated form of theinvention, two switches, in addition to the normal gun switches, areprovided on the simulator robot spray gun: a programming start/stoppushbutton switch and an auxiliary function sequencing pushbuttonswitch. In order to start a training session, to begin the storage oflink position commands, gun commands, and auxiliary function commands inthe controller robot program memory, the simulator operator depressesthe start/stop programming switch on the gun. At the completion ofrecording of a program, the simulator operator depresses the start/stopprogramming pushbutton switch again to end the training session andconclude the recording of commands in the robot program memory.

During the training session, whenever an auxiliary function must beexecuted and recorded, the simulator operator depresses the sequencingpushbutton, and the controller reads the next auxiliary functioncommand, in sequence, from the auxiliary function memory. The auxiliaryfunction is executed during the training session, and the auxiliaryfunction command is also stored in the robot program memory togetherwith the link position commands and the gun commands at a point in thesequence of link position commands correlated to the point in thesequence at which the sequencing pushbutton is depressed by thesimulator operator. In this way, during a training session, thesimulator operator has only one additional control to consider, and theneed for a second operator at the control console during a trainingsession is eliminated.

Other objects and advantages of the invention, and the manner of theirimplementation, will become apparent upon reading the following detaileddescription and upon reference to the drawings, in which:

FIG. 1 is a perspective view, in schematic form, of a typicalwork-performing robot, or manipulator, showing the general relationshipof the relatively massive robot links and their respectively associatedactuators and position transducers;

FIG. 2 is a perspective view, in schematic form, of a lightweight,hand-manipulable simulator robot, or training arm, showing the generalrelationship of the simulator links and associated position transducers;

FIG. 3 is a circuit diagram in block format of a preferred embodiment ofthe invention;

FIG. 4a, 4b and 4c are a flow charts of illustrative form of robotsystem embodying the present invention; and

FIG. 5 is a perspective view, in schematic form, of a paint spray gun atthe end of the simulator robot arm of FIG. 2, together with a part to besprayed and an auxiliary device for turning the part.

While the invention is susceptible to various modifications andalternative forms, a specific embodiment thereof has been shown by wayof example in the drawings and will herein be described in detail. Itshould be understood, however, that it is not intended to limit theinvention to the particular form disclosed, but, on the contrary, theintention is to cover all modifications, equivalents, and alternativesfalling within the spirit and scope of the invention as defined by theappended claims.

The invention shall be described herein with relation to a controlsystem for storing a sequence of link position commands, gun commands,and auxiliary function commands for a work-performing robot for spraypainting a work piece. With reference to FIG. 1, a typicalwork-performing robot, or manipulator, includes a base 10 which rests onthe floor or upon a movable table (not shown) which may be indexed to anumber of positions. Extending from the base 10 are plural,series-connected, elongated, articulated members or links 12, 14, 16,18, 20 and 22 which, in the preferred embodiment, provide the robot withseveral, in this instance six, degrees of freedom. In practice, thelinks 12, 14, 16, 18, 20 and 22 collectively constitute a relativelylarge mass. For example, the links 12, 14, and 16 are each approximately1-4 feet in length, and typically weigh in the range of 10-400 poundseach. The links 18, 20 and 22 which, in the work-performing robot shownin FIG. 1 constitute a wrist, typically are significantly less massivethan the links 12, 14 and 16, although this is not necessarily the case.

The link 12 is vertically disposed and mounted to the base 10 by asuitable joint which permits the link to rotate about its longitudinalaxis, which is coincident with the X axis. An actuator 23 is associatedwith the link 12, and is responsive to a position error signal providedby a conventional robot controller (not shown in FIG. 1) to facilitateselective, bidirectional angular motion of the link 12 in an azimuthaldirection about its longitudinal axis to the desired link position. Alsoassociated with the link 12 is a position transducer, or resolver, 24which provides an electrical signal correlated to the actual angular, orazimuthal, position of the link 12 relative to the base 10.

The link 14 at its lower end is connected to the upper end of the link12 by a suitable joint for permitting pivotal, elevational movement ofthe link 14 in a vertical plane about a horizontal axis 26 which isperpendicular to the X axis and parallel to the Y-Z plane. Associatedwith the link 14 is an actuator 28 which is responsive to a positionerror signal from the robot controller and facilitates selective,bidirectional, elevational, pivotal movement of the link 14 abouthorizontal axis 26 to the desired link position. Also associated withthe link 14 is a position transducer 30 which provides an electricalsignal correlated to the actual elevational position of the link 14relative to the link 12.

In like manner, the links 16, 18, 20 and 22 are interconnected bysuitable joints and have associated actuators 33, 44, 48 and 52,respectively. Each of the link actuators is responsive to a positionerror signal from the robot controller to facilitate movement of each ofthe links to the desired link position. Also associated with each of thelinks 16, 18, 20 and 22 is a position transducer 34, 46, 50 and 54,respectively. Each of these position transducers provides an electricalsignal correlated to the actual position of its associated link. Thearticulated links 18, 20 and 22 collectively constitute a wrist.

The link 22 constitutes the mechanical output element of thework-performing robot. While the mechanical output of the robot can beutilized for positioning a wide variety of devices, in the illustratedform of the invention the work-performing robot is utilized to positiona spray coating gun 58 having a barrel 58a with a nozzle 58b which emitscoating particles. The gun handle 58c is mounted to the upper end of thewrist link 22. The gun handle 58c mounts a suitable trigger mechanism58d which, when actuated by a suitable signal-operated device (notshown), functions to operate a valve to control the emission of coatingparticles from the nozzle 58b of the spray gun 58. The nozzle 58b ispositioned between a pair of spray fan air outlets 58e, 58f coupled to asource of pressurized air (not shown) for shaping the pattern of thespray emanating from the nozzle 58b. The trigger mechanism 58d is athree position trigger. The three trigger positions are "off", "on"(paint being discharged by the gun with a first spray fan patternactivated), and "on/fan" (paint being discharged by the gun with asecond spray fan pattern activated). The spray gun 58 further includesan electrode (not shown) for electrostatically charging the paintsprayed by the gun 58 which is coupled from a source of electrostaticvoltage (not shown) under the control of an electrostatic switch,illustrated as a toggle switch 58g.

The longitudinal rotational axes of the wrist links 18, 20 and 22 aremutually perpendicular, and accordingly constitute three degrees offreedom for the robot. These three degrees of freedom, coupled with thethree degrees of freedom of the links 12, 14 and 16, provide a total ofsix degrees of freedom for the work-performing robot.

In the operation of the work-performing robot shown in FIG. 1, a seriesof programmed, i.e., desired, link position command signals stored in asuitable robot program memory device of the robot controller areperiodically retrieved and compared against the actual link positionsignals provided by the link position transducers 24, 30, 34, 46, 50 and54, and in response thereto link positional error signals are generatedfor each of the links 12, 14, 16, 18, 20 and 22. The positional errorsignals for the various links 12, 14, 16, 18, 20 and 22 are then inputto the various link actuators, 23, 28, 33, 44, 48 and 52, whichtypically are of the servo-controlled electrohydraulic type, for movingthe links to the desired, or programmed, command positions which in turnreduce the positional error signals to zero. Thus, the links of thework-performing robot of FIG. 1 are driven through the programmedsequence of desired motions, or command positions, utilizing closed-loopservo techniques, by periodically comparing desired position commandsignals retrieved from the memory of the robot controller with actuallink position signals from their associated position transducers, andusing the resulting positional error signals associated with thedifferent links to drive the various link actuators to the desired, orprogrammed, command positions.

During the operation of the work-performing robot gun commands,interleaved at proper points in the sequence of link position commands,are coupled to the electrostatic and spray trigger controls of the gun58. In response to these gun commands, the paint flow, air andelectrostatic charging mechanism at the gun are operated in relation tothe gun position established by the link position commands.

Since a robot controller, actuators, position transducers, closed-loopservo controls, and the like for the work-performing robot of FIG. 1 arewell known and form no part of this invention, they are not furtherdiscussed in detail herein, except to the extent necessary to anunderstanding of the flow charts of FIG. 4.

The robot simulator, or training arm, shown in FIG. 2, which is usefulin preparing a programmed sequence of motions for input to the workrobot for execution thereby relative to a workpiece, includes a tripodbase 110 from which extends vertically a link 112 which is connected tothe base for rotational movement about a vertical axis by a rotary joint123. A position transducer 124 associated with the link 112 and base 110provides an electrical signal correlated to the actual angular positionof the link 112 relative to the stationary base. Pivotally connected tothe upper end of the link 112 by a rotary joint 128 is a link 114 whichpivots about axis 126. An angular position transducer 130 associatedwith the joint 128 and the link 114 provides an electrical signalcorrelated to the actual angular position of the link 114 with respectto the link 112. A link 116 connects to the link 114 via a rotary joint133 for pivotal movement about axis 132. An angular position transducer134 associated with the joint 133 and the link 116 provides anelectrical signal correlated to the actual angular position of the link116 with respect to the link 114.

Also included in the robot simulator depicted in FIG. 2 are links 118,120 and 122 which are pivotally connected to links 116, 118 and 120,respectively, via rotary joints 144, 148 and 152, respectively. Angularposition transducers 146, 150 and 154 associated with the rotary joints144, 148 and 152, respectively, and the links 118, 120 and 122,respectively, provide electrical signals correlated to the actualangular position of the links 118, 120 and 122 with respect to the links116, 118 and 120, respectively.

The length of the links 112, 114, 116, 118, 120 and 122 of the simulatorrobot of FIG. 2 are identical to the lengths of the links 12, 14, 16,18, 20 and 22, respectively, of the work-performing robot shown inFIG. 1. Of course, the mass of the links 112, 114, 116, 118, 120 and 122of the simulator robot of FIG. 2 are a mere fraction of that of theircounterpart links 12, 14, 16, 18, 20 and 22 of the considerably moremassive work-performing robot shown in FIG. 1. Similarly, the joints123, 128, 133, 144, 148 and 152 of the simulator robot permit the sametype of pivotal motion between their respectively associated links 112,114, 116, 118, 120 and 122 as their counterpart rotary actuators 23, 28,33, 44, 48 and 52 provide for their respectively associated links 12,14, 16, 18, 20 and 22 of the work-performing robot.

The articulated links 118, 120 and 122 collectively constitute a wrist,and the link 122 constitutes the mechanical output element of thesimulator robot. In correspondence with the work robot of FIG. 1, themechanical output of the simulator comprises a spray coating gun 158having a barrel 158a with a nozzle 158b which emits coating particles.The gun handle 158c is mounted to the upper end of the wrist link 122.The gun handle 158c mounts a suitable trigger mechanism 158d which, whenactuated by the operator of the simulator, functions to control theemission of coating particles from the nozzle 158b of the spray gun 158.The nozzle 158b is positioned between a pair of spray fan air outlets158e, 158f coupled to a source of pressurized air (not shown) forshaping the pattern of the spray emanating from the nozzle 158b. Thetrigger mechanism 158d is a three-position trigger. The three triggerpositions correspond to those for the work robot trigger 58d and are"off", "on/fan", and " on". The spray gun 158 further includes anelectrode (not shown), for electrostatically charging the paint sprayedby the gun 158, which is coupled from a source of electrostatic voltage(not shown) under the control of a switch illustrated as a toggle switch158g.

When the spray gun 158 is moved manually, by an operator grasping thehandle 158c thereof, through a sequence of motions necessary to spraycoat an object, which is possible due to the lightweight construction ofthe simulator, the various links 112, 114, 116, 118, 120 and 122 of thesimulator robot move through a sequence of motions. Simultaneously, thetransducers 124, 130, 134, 146, 150 and 154 of the simulator robotassociated with the various simulator robot links 112, 114, 116, 118,120 and 122 provide electrical outputs corresponding to the actualsequence of positions, or motions, through which the simulator robotlinks move in the course of manually moving the gun through thepositions necessary to coat the object. These transducer signalscorresponding to the actual positions of the different simulator robotlinks can be input directly to the robot controller or recorded by anysuitable means (not shown).

The spray gun 158 on the simulator contains the same elements andcontrols 158a-158g as the corresponding elements 58a-58g of the gun 58utilized by the work robot. In the course of moving the gun 158 throughthe sequence of motions necessary to spray paint a work piece, theoperator of the simulator periodically manually actuates the trigger158d to permit paint to be discharged from the gun nozzle 158b.Depending upon the position of the trigger, the compressed air from thespray fan outlets 158e, 158f may also be provided to shape the spraypattern from the nozzle. The simulator operator also activates theelectrostatic switch 158g to apply electrostatic charge to the sprayedpaint.

By recording signals corresponding to the position of the switch 158d inconjunction with recording the position signals provided by the actualposition transducers 124, 130, 134, 146, 150 and 154 of the simulatorrobot for the entire sequence of motions of the simulator robot links112, 114, 116, 118, 120 and 122 produced by manual manipulation by theoperator of the gun 158, a sequence of coordinated gun switch commandsignals and desired robot link position signals can be stored. In likemanner, the operator can utilize the electrostatic charging feature ofthe spray gun, by activating the toggle switch 158g during a trainingsession for a spray coating operation. Signals indicative of theposition of the toggle switch 158g are coordinated with the robot linkposition commands and stored.

These stored signals (link position commands interleaved with guncommands) are maintained within the robot controller, as a paintingprogram, in a mass memory device such as a bubble memory. Thereafter,when it is desired to operate the work robot under the control of thestored program, the recorded link position commands input to the robotcontroller for use by the work-performing robot are sequentiallyretrieved and compared with signals correlated to the actual work robotlink positions; and link position error signals are derived for input tothe work robot link actuators to cause the work robot links to reproducethe motion of the simulator robot links in the manner previouslydescribed. In addition, gun commands interleaved with the link positioncommands are retrieved, and the gun switches are activated in theappropriate timed relationship to the motion of the robot links toeffect spray painting of the work piece.

Associated with the simulator robot and work robot of an illustrativerobot system with which this invention is useful is a robot controller200, which preferably comprises a microprocessor-based control circuit.The robot controller 200 includes a mass memory device, such as a bubblememory, serving as a robot program memory for storing a programmedsequence of desired or command positions for driving the various workrobot links 12, 14, 16, 18, 20 and 22, as well as suitable buffer memoryfor temporarily storing the actual and desired positions of the workrobot links and the computed positional errors therebetween which resultwhen the work robot is input with, that is, driven by, the programmedsequence of desired positions stored in the robot controller memory.Also included in the robot controller 200 are computing means forcomparing desired work robot link positions with actual work robot linkpositions temporarily stored in the buffer memory and deriving inresponse thereto work robot link position error signals for input to thelink actuators 23, 28, 33, 44, 48 and 52 of the work robot. Duringprogram generation, teaching or training, signals correlated to thedesired work robot link positions 200 from simulator robot transducers124, 130, 134, 146, 150 and 154 are input to the robot controller onlines 202 via a resolver-to-digital converter 203 connected via lines204 to the simulator robot position transducers. During programexecution, or playback, signals correlated to the actual work robot linkpositions from work robot position transducers 24, 30, 34, 46, 50 and 54are input to the robot controller on lines 205 via a resolver-to-digitalconverter 206 connected via lines 207 to the work robot positiontransducers, while the work robot link position error signals computedby the robot controller are output to the respective link actuators 23,28, 33, 44, 48 and 52 of the work robot on lines 208 via adigital-to-analog converter 209 which receives the link position errorsignals on output lines 210.

The robot controller mass memory also stores gun commands interleavedwith the sequence of link position commands. The gun commands includecommands for effecting the desired condition of the OFF/ON/FAN switch58d of the work robot. These OFF/ON/FAN switch condition signals areinput during program generation to the robot controller memory on line211, and are output during program execution to the memory to theOFF/ON/FAN switch 58d of the work robot on line 212. Likewise, guncommands for the electrostatic switch are input during programgeneration to the robot controller memory on line 221, and are outputduring program execution from the memory to the electrostatic switch 58gof the work robot on line 222.

In a given robot system, both during program recording or training withthe simulator robot and during program execution or replay by the workrobot, the controller 200 processes position command signals at aspecific rate, which may be constant or vary with time. The rate may bethe same or different during program recording and program execution.For example, assuming during program execution that there is nointerpolation by the controller 200 and no relative movement between theobject being coated by the robot and the work station whereat the robotis located, the controller position command signal processing rate willbe the same during both program recording and program execution. Thus,if there are six robot axes, during program recording the robotcontroller will sample and store in memory for each simulator robot axisN simulator robot link position transducer signals (desired positions)per second. Similarly, during program execution the controller will, Ntimes per second for each axis, fetch from memory a position command(desired position) to be used to drive the link actuator for that axis.In a typical situation, N is 16, although other controller processingrates can be used if desired.

If interpolation is employed by the controller 200 during programexecution to compute additional position commands between a pair ofsequential position commands stored in memory, the number of positioncommands per axis per second issued to the work robot will be greaterthan the number of position signals from the simulator robot sampled andrecorded by the controller per second per axis.

If there is relative motion between the object being painted and therobot work station during program recording and program execution, theposition command processing rate of the controller 200 may vary withtime if the speed of the conveyor transporting the article being coatedis varying with time and it is used to control the rate at which thecontroller fetches position commands (desired position) from memory.Sampling of the work robot actual link positions and computationstherefrom of position error signals, which are output to the linkactuators of the work robot, are accomplished at a desired set rate.This rate is independent of the rate at which the controller fetchesposition commands from memory.

For convenience, during program execution, the rate per axis at whichthe controller 200 fetches commands from memory is referred to herein asthe controller "command position processing rate". The rate duringprogram recording at which the controller 200 samples and stores inmemory the OFF/ON/FAN signals output from the simulator robot switch158d and the electrostatic signals from the switch 158g, and the rate atwhich the controller during program execution fetches from memory thestored OFF/ON/FAN signals and electrostatic signals, may be equal to oneanother as well as to the command position processing rate.

The robot controller mass memory further stores commands related toauxiliary functions to be performed in the execution of a paintingprogram in conjunction with the movement of the work robot links and theoperation of the spray gun switches. These auxiliary functions areimplemented by a number of auxiliary output devices 401 and an exemplaryauxiliary output device, a servo motor 402 to turn the work piece beingpainted. The auxiliary functions further include a number of auxiliaryinputs from input devices 404 and an exemplary auxiliary input, from alimit switch 406 indicative of completion of the turning of the workpiece. Auxiliary function commands associated with auxiliary outputs arecoupled during program execution from the robot program memory to theauxiliary output devices 401, 402. Auxiliary function commandsassociated with auxiliary inputs direct the controller to read thecondition of the auxiliary input devices 404, 406 during programexecution.

Other auxiliary output devices 401 may include, for example, a motor forindexing a movable robot table, a color change mechanism for changingthe color of the paint applied by the spray gun 58, or a control for theactivation of an exhaust fan for a spray painting booth. Other auxiliaryinputs 404 may include, for example, a limit switch for indicating thata movable robot table has reached a desired position or a sensorproducing a signal indicating the presence of a particular physicalcharacteristic in the shape of the work piece.

In accordance with the invention, auxiliary function commands aresupplied during a training session for execution and for storage in therobot program memory from an auxiliary function memory 407. Prior to thetraining session, auxiliary function commands are written into theauxiliary function memory from the controller 200 on a line 410. Duringthe training session, the auxiliary function commands are read from theauxiliary function memory 407 on a line 405.

As shall be described in more detail hereinafter, the auxiliary memory407 is loaded with a sequence of auxiliary commands so that the commandscan be read from the auxiliary memory in the order in which they are tobe executed during the training session. Then, when the operator of thesimulator robot manipulates the simulator to produce a sequence of linkposition commands, and activates the gun switches 158d and 158g toproduce the gun commands, the operator also activates a switch to directthe controller to read the auxiliary function commands, in sequence, atdesired times during the training session, from the auxiliary memory.

In order to do this, the operator of the simulator robot depresses asequence pushbutton switch 158i on the gun, which is coupled to therobot controller by a line 214, and the robot controller is responsiveto the switch 158i to read the next auxiliary function command, insequence, from the auxiliary memory 407. Each time the simulatoroperator activates the sequence switch 158i, the next auxiliary functioncommand in the auxiliary memory is read, executed and stored in therobot program memory by the controller 200. The point in the sequence oflink position commands in the program memory at which the auxiliaryfunction command is stored is correlated to the point in the sequence oflink position commands at which the simulator operator depresses thesequence pushbutton 158i.

Prior to a training session for recording a spray painting program, theauxiliary memory 407 is loaded with the necessary auxiliary functioncommands by the operator of the simulator. This is accomplished byutilizing the robot controller computer, keyboard and display. Theauxiliary function commands are loaded into the auxiliary memory 407 insuch a manner that they are read from the auxiliary memory in thesequence in which they are to be executed during a training session.Normally, this permits loading the commands into the auxiliary memory inthe order in which the commands are to be read out of the memory,although this is not necessarily the case.

In order to permit the simulator operator to begin and end a trainingsession, a second pushbutton switch, a program switch 158h, on the gun158 is coupled to the robot controller on a line 213. When the simulatoroperator wishes to begin a training session, initiating the recording oflink position commands, gun commands and auxiliary function commands,the operator depresses the program switch 158h, and the robot controllerbegins storing the commands in the robot program memory. When thesimulator operator has completed programming, and wishes to end thetraining session and the recording of commands, the operator depressesthe pushbutton program switch 158h, and the robot controller stopsstoring commands in the robot program memory, ending the trainingsession. Since the program switch 158h is provided at the spray gun 158,the simulator operator can begin and end a training session whileoperating the simulator at the work site.

FIG. 4a is an illustrative flow chart of the routine followed by therobot controller computer in loading the auxiliary memory 407. Withreference to FIG. 4a the procedure for loading the auxiliary memory 407calls for inputting items of sequence data (each of the auxiliaryfunction commands) through the controller keyboard (301) and the storageof each entry in the auxiliary memory (302). After each auxiliaryfunction command is stored, a sequence entry pointer is incremented(303) so that the next auxiliary function command is stored in the nextmemory location. Any convenient prompting scheme utilizing the displayof the robot controller 200 may be utilized to assist the operator inentering the sequence of auxiliary function commands. After the lastcommand is entered, the sequence set-up routine ends (304). Theauxiliary memory 407 is then loaded so that the robot controller canread the auxiliary function commands, in the sequence they are to beexecuted, from the auxiliary memory during the operation of thesimulator robot in a training session.

The particular format for the entry of the auxiliary function commandsis not critical to the invention. In one form of auxiliary memory andcontroller, one or more of three types of auxiliary function commandscan be stored in the auxiliary memory at each of eight sequentialstorage locations. In that way, at each of the eight storage locations,auxiliary function commands are stored which may be characterized asauxiliary outputs, auxiliary inputs, or delays. The auxiliary functioncommands at each of the storage locations, one through eight, are readby the robot controller as each memory location of the auxiliary memoryis sequentially addressed by successive actuations of the pushbuttonsequencing switch 158i.

After all necessary auxiliary commands have been stored in the auxiliaryfunction memory, a painting program may be prepared by the simulatoroperator without the need for assistance from an additional operator. Inorder to record a programmed sequence of motions with respect to aworkpiece for subsequent execution or replay by the work robot, theworkpiece is first located at the site of the simulator robot. Theoperator of the simulator robot, having previously loaded the auxiliarymemory 407, is now able to perform the complete programming operation atthe location of the simulator robot. The operator first depresses theprogram switch 158h on the gun, and the robot controller 200 beginsstoring a program for subsequent control of the work robot and auxiliaryfunctions.

After depressing the program switch 158h, the operator manipulates thesimulator robot through the desired sequence of motions with respect tothe workpiece. While the operator is manipulating the simulator robot,the outputs of the link position transducers 124, 130, 134, 146, 150 and154 of the respective simulator robot links are input to the controller200 via the R/D converter 203 where they are sampled, buffered andrecorded in memory (305). Additionally, the condition of the robotsimulator OFF/ON/FAN switch 158d and the condition of the electrostaticswitch 158g are input to the controller 200 on the lines 211, 221,respectively. These inputs are also sampled (306), buffered and recordedin memory.

As shown in the flow chart of FIG. 4b, after the recording of positioncommands for each of the six links of the simulator robot (307), theOFF/ON/FAN and electrostatic switch conditions are recorded (308). Inpractice, the gun switch conditions are sampled each time a linkposition command is recorded. Thereafter, when the gun switch conditionsare recorded, there is also recorded an indication of the point duringaxis command recording at which a gun switch condition changed. Thisincreased frequency of gun switch sampling is done to improve theresolution of gun switch control during program execution. Six axiscommands and a related set of gun commands may be regarded as a "group"of commands. The controller loops through the recording of eight groupsof commands (309) before checking for auxiliary commands. Afterrecording eight groups of commands, the controller checks to determineif the gun sequence switch 158i is on (310). If not, the controllercycles through another eight groups of link and gun switch commands forstorage in the robot program memory. The reduced frequency of recordingauxiliary function commands, relative to the frequency of recordinggroups of axis and gun commands, is used to conserve program memoryspace since the resolution required for execution of the auxiliaryfunctions is relatively less than that required for the other functions.

If the operator has activated the gun sequence switch, the controllerchecks to determine if the final set of auxiliary function commands havealready been written (311) from the auxiliary memory 407. If it has, thecontroller ignores the activation of the gun sequence switch and returnsto the beginning of the routine. If the controller has not yet reachedthe end of the sequence of auxiliary function commands in the auxiliarymemory 407, the controller reads the next set of auxiliary functioncommands in the sequence (312) from the auxiliary memory 407. Then thecontroller increments the sequence entry pointer (313) to the next setof auxiliary function commands in the sequence.

Since the controller checks the condition of the sequence switch 158iafter each eight groups of link position commands, the auxiliaryfunction command or commands read by the controller when the sequenceswitch is activated are read in timed relationship to the movement ofthe simulator by the operator.

In order to produce a painting program, the operator of the simulatorrobot not only moves the simulator to produce a sequence of linkposition commands, but also actually spray paints a work piece. In thisway, the simulator operator can determine during the simulation that thespray painting pattern produced has satisfactorily painted the workpiece. During a training session, the simulator operator moves the gunand operates the gun switches and the activation of the gun switches iseffective to control the functions of the gun. In like manner, in orderto properly record a complete command sequence, the auxiliary functionsread from the auxiliary function memory when the operator depresses thesequence switch 158i are performed in timed relationship to the movementof the gun during the training session.

Therefore, after the controller has read a set of auxiliary functioncommands in sequence from the auxiliary memory, the controller thenexecutes the auxiliary commands. If the auxiliary function to beexecuted is an auxiliary output, the controller issues a command to theappropriate output device to perform the auxiliary function (314). Ifthe auxiliary function is an auxiliary input, the controller reads thecondition of the input line from the auxiliary input device (315). Ifthe auxiliary function is a delay, the controller pauses in therecording of link position commands and gun commands until the end ofthe delay interval.

After the execution of an auxiliary function, the controller thenstores, in the robot program memory, the associated auxiliary functioncommand interleaved with the link position commands at the point in thesequence of link position commands where the sequence switch wasactivated by the operator. Consequently, by preloading the auxiliaryfunction commands in the auxiliary memory 407, the operator needs merelyto operate a single sequence switch 158i at the simulator robot gun 158to both execute and store each auxiliary function at the proper point inthe sequence of link position commands. The controller continues to loopthrough the routine illustrated in FIG. 4b until the operator againactivates the program switch 158h, ending the programming routine (316).

In storing the program to be executed by the work robot, the controllerstores "instructions" which each include eight groups of commands. Eachof these groups of commands includes six link position commands, anOFF/ON/FAN switch condition signal, and an electrostatic switchcondition signal. Each instruction may also include a set of auxiliaryfunction commands. The sequence of instructions forms the completeprogram for the work robot.

As an example of the reading, execution and storage of auxiliaryfunction commands, a flat panel work piece 403 to be painted isrotatable by a servo motor 402 and has an associated position-indicatinglimit switch 406 as shown in FIG. 5. The panel 403 is positioned to bespray painted by the simulator robot gun 158. The gun, servo motor, andlimit switch are coupled to the robot controller as illustrated in FIG.3.

In the course of producing a spray painting program in a trainingsession, the operator of the simulator must spray paint one side of thepanel 403, wait while the panel is rotated 180°, and then spray paintthe other side of the panel. Painting the two sides of the panelconstitutes a complete spray painting program. Prior to the trainingsession, the operator loads the auxiliary function memory 407 with thenecessary auxiliary function commands in the order in which they are tobe read, executed and stored during the training session.

If there are other auxiliary function commands to be executed during thetraining session, in addition to those associated with turning the panel403, the commands for turning the panel must be properly located in thesequence of auxiliary function commands so that those auxiliaryfunctions needed before the part is turned are read from the auxiliaryfunction memory first, and those auxiliary function commands neededafter the panel has been turned are stored in the auxiliary functionmemory after the auxiliary function commands for turning the panel. Inthe present example, assuming that the auxiliary function commandsassociated with turning the panel 403 are the only auxiliary functioncommands to be executed, the first storage location in the auxiliaryfunction memory is loaded with a "turn part" command. This is anauxiliary output function command which, when executed, activates theservo motor 402 to rotate the panel 180°. In the next memory location inthe auxiliary function memory, two auxiliary function commands arestored. The first is a delay command. When this command is executed, therobot controller stops recording link position commands for thespecified delay interval. In the present example, the delay interval isfive seconds. If the execution of the painting program is synchronizedwith movement of the panel on a conveyor, the five second delay may beconsidered to be a five second delay at nominal conveyor speed. In thiscase the delay will vary with the actual conveyor speed during executionof the painting program. At the same auxiliary function memory location,there is also stored an auxiliary input function command, which whenexecuted directs the controller to read the condition of the limitswitch 406. The limit switch is activated after the panel 403 has beenrotated through 180°. The controller is operable to execute a delaycommand prior to executing an auxiliary input command, when they arestored at the same auxiliary function memory location, so the delay isimplemented before the condition of the limit switch 406 is read by thecontroller.

After the requisite auxiliary function commands are stored in theauxiliary function memory 407, the simulator operator begins thetraining session by depressing the program switch 158h. In the course ofspray painting the panel 403, the simulator operator, aftersatisfactorily spray painting one side of the panel, depresses thesequence switch 158i and the controller reads the "turn part" auxiliaryfunction command from the auxiliary function memory. The controlleroutputs the command to the servo motor 402 to turn the work piece. Thecontroller also records the "turn part" command in the sequence of linkposition commands and gun commands, at a point in the link commandsequence corresponding to the point in the link command sequence atwhich the operator depresses the sequence switch 158i.

When the operator depresses the sequence switch 158i to effect theturning of the panel 403, the operator also turns off the paint sprayusing the gun trigger switch 158d. The operator must now wait for thepanel 403 to be rotated through 180° before beginning to spray paint theother side of the panel. In order to conserve space in the robot programmemory, it is desirable not to record the link positions during thedelay interval for the rotation of the panel. Therefore, the simulatoroperator again depresses the sequence switch 158i. In response to thissecond activation of the sequence switch, the controller reads theauxiliary function commands at the second storage location in theauxiliary function memory. These commands are the five second delay andthe auxiliary input command to read the condition of the limit switch406.

The controller first executes the delay command, by ceasing to recordlink position commands and gun commands for the duration of the delayinterval of five seconds. After the expiration of the five second delay,the controller then responds to the auxiliary input command to check thecondition of the limit switch 406. If for some reason the limit switchhas not been activated, indicating that the panel 403 has not reachedits proper position within the five second delay interval, thecontroller aborts the training session and provides some type of audibleand/or visible alarm to the simulator operator.

If the limit switch 406 has been properly activated, indicating that thepanel 403 has been rotated through 180°, the controller resumesrecording link position commands, gun commands and auxiliary functioncommands. The simulator operator then proceeds to spray paint the secondside of the panel 403, to complete the spray painting program for thepanel. When the operator has completed spray painting the panel, theoperator depresses the program switch 158h, which ends the recording ofcommands by the controller and terminates the training session.

Following reading, reformatting if necessary, and storage in the robotprogram memory of the program of commands, the work robot drive phase,or program execution or replay, may be initiated, as shown in the flowchart of FIG. 4c. The steps shown in the flow chart are sequentiallyrepeated, at the controller command position processing rate.Considering only a single instruction, the robot controller programexecution shall now be described. The desired gun switch conditions of afirst group of commands are retrieved (317) from the robot controllermemory and transferred to the gun switches (318) of the work robot vialines 212, 222. The timing of the application of a gun command to a gunswitch is correlated to the recorded indication of the point during axiscommand recording that the gun switch condition changed.

Next the desired work robot link position for the first link of a groupis retrieved from the robot controller memory (319). The actual positionof the work robot link in question is input via its respective line 207and R/D converter 206 to the robot controller buffer register (320), andthe desired and actual work robot link positions are then compared and awork robot link position error for that particular link is computed bythe robot controller (321). The work robot link position error signal isoutput via its respective line 210 to its respective work robot linkactuator (322) via D/A converter 209 to position the work robot link.

These steps are repeated for each of the six desired work robot linkposition signals in a group of commands (323). When all desired workrobot link position signals in the group have been processed in themanner indicated, the controller determines if eight groups of commandshave been executed (324). The controller loops through the execution ofcommands, as described, if eight groups of commands have not beenexecuted. After the execution of eight groups of commands, thecontroller then retrieves any auxiliary data which might be present inthe instruction from the controller memory (325), outputs the auxiliarydata to the auxiliary output devices and, if commanded, executes anydelays and reads any necessary auxiliary inputs (326). This completesthe execution of the robot controller program for a single instructionof link position, gun switch and auxiliary function commands. Theforegoing steps, illustrated in the flow chart of FIG. 4c, are repeatedfor each instruction until all instructions have been input to the workrobot to drive it through the desired sequence of motions which wereprogrammed with the simulator robot at the workpiece site and stored inthe controller memory during the program recording phase. When this hasoccurred, the program terminates (327).

Operation of the robot controller 200 at all times is under control ofmain, or supervisory, programs which, in addition to controlling,recording and executing a sequence of desired link positions stored inmemory, are also operative to facilitate such things as: turn-on andturn-off of the entire robot system when an appropriate POWER ON/OFFswitch (not shown) is activated, continuous monitoring of hydraulicpressure levels in all work robot link actuators, orderly interruptionof execution of the stored sequence of link positions by the work robotwhen a STOP button (not shown) is actuated, control of the orderly flowof data between the various components of the controller and/or betweenthe work and simulator robots and the controller, effecting variousdiagnostic, interlock and safety routines, etc. The main or supervisoryprograms are interrupted, as necessary, to accomplish the routines andsubroutines shown in FIG. 4.

What is claimed is:
 1. A control system for a work robot comprising:acontroller for concurrently (a) driving at least one articulated robotlink under closed loop servo control and (b) executing at least oneauxiliary function operating in conjunction with the robot link, inresponse to a sequence of link position commands and auxiliary functioncommands read from a robot program memory; an auxiliary function memory,associated with the controller, for temporarily storing auxiliaryfunction commands; means for loading the auxiliary function memory withauxiliary function commands, prior to storing a sequence of linkposition commands and auxiliary function commands in the robot programmemory, so that the auxiliary function commands can be read from theauxiliary function memory in a desired order; a robot simulator manuallymanipulable to produce a sequence of robot link position commands;manually operated auxiliary function command sequencing means foreffecting the reading of each auxiliary function command, in order, fromthe auxiliary function memory at a point in the sequence of robot linkposition commands correlated to the point during the sequence of robotlink position commands at which the sequencing means is manuallyoperated; and memory means in the controller, coupled to the robotsimulator and to the auxiliary function memory, including a robotprogram memory for storing the sequence of link position commandsproduced by the simulator interleaved with the auxiliary functioncommands read from the auxiliary function memory, each auxiliaryfunction command being stored at a point in the sequence of robot linkposition commands correlated to the point in the sequence of robot linkposition commands at which the auxiliary function command sequencingmeans is manually operated.
 2. The control system of claim 1 whichfurther comprises means for implementing each auxiliary function commandas it is read from the auxiliary function memory for storage in therobot program memory.
 3. The control system of claim 2 which furthercomprises an auxiliary output device not associated with the robot linkand in which the means for implementing auxiliary function commandsincludes means for providing an auxiliary output command to theauxiliary output device to activate the device.
 4. The control system ofclaim 2 which further comprises an auxiliary input device not associatedwith the robot link and in which the means for implementing auxiliaryfunction commands includes means for reading the condition of theauxiliary input device in response to an auxiliary input functioncommand read from the robot program memory.
 5. The control system ofclaim 3 which further comprises an auxiliary input device not associatedwith the robot link and in which the means for implementing auxiliaryfunction commands includes means for reading the condition of theauxiliary input device in response to an auxiliary input functioncommand read from the robot program memory.
 6. The control system ofclaim 5 in which the controller drives a plurality of articulated robotlinks, which comprise a work robot, under closed loop servo control formovement relative to a work piece, and the auxiliary output deviceincludes means for varying the orientation of the work piece relative tothe work robot.
 7. A control system for a work robot which includes aspray coating gun for applying a spray coating to a work piececomprising:a controller for concurrently (a) driving at least onearticulated robot link under closed loop servo control, (b) executing atleast one spray gun command in conjunction with the robot link, and (c)executing at least one auxiliary function operating in conjunction withthe robot link, in response to a sequence of link position commands, guncommands, and auxiliary function commands read from a robot programmemory; an auxiliary function memory, associated with the controller,for temporarily storing auxiliary function commands; means for loadingthe auxiliary function memory with auxiliary function commands, prior tostoring a sequence of link position commands and auxiliary functioncommands in the robot program memory, so that the auxiliary functioncommands can be read from the auxiliary function memory in a desiredorder; a robot simulator manually manipulable to produce a sequence ofrobot link position commands; a robot simulator spray gun manuallyoperable to produce gun commands for controlling the flow of coatingmaterial from the gun; manually operated auxiliary function commandsequencing means for effecting the reading of each auxiliary functioncommand, in order, from the auxiliary function memory at a point in thesequence of robot link position commands correlated to the point duringthe sequence of robot link position commands at which the sequencingmeans is manually operated; and memory means in the controller, coupledto the robot simulator, the simulator spray gun, and the auxiliaryfunction memory, including a robot program memory for storing thesequence of link position commands produced by the simulator interleavedwith the gun commands and the auxiliary function commands read from theauxiliary function memory, each auxiliary function command being storedat a point in the sequence of robot link position commands correlated tothe point in the sequence of robot link position commands at which theauxiliary function command sequencing means is manually operated.
 8. Thecontrol system of claim 7 which further comprises means for implementingeach auxiliary function command as it is read from the auxiliaryfunction memory for storage in the robot program memory.
 9. The controlsystem of claim 8 which further comprises an auxiliary output device notassociated with the robot link and in which the means for implementingauxiliary function commands includes means for providing an auxiliaryoutput command to the auxiliary output device to activate the device.10. The control system of claim 8 which further comprises an auxiliaryinput device not associated with the robot link and in which the meansfor implementing auxiliary function commands includes means for readingthe condition of the auxiliary input device in response to an auxiliaryinput function command read from the robot program memory.
 11. Thecontrol system of claim 9 which further comprises an auxiliary inputdevice not associated with the robot link and in which the means forimplementing auxiliary function commands includes means for reading thecondition of the auxiliary input device in response to an auxiliaryinput function command read from the robot program memory.
 12. Thecontrol system of claim 11 in which the controller drives a plurality ofarticulated robot links, which comprise a work robot, under closed loopservo control for movement relative to a work piece, and the auxiliaryoutput device includes means for varying the orientation of the workpiece relative to the work robot.
 13. A control system for a work robotcomprising:a controller for concurrently (a) driving at least onearticulated robot link under closed loop servo control and (b) executingat least one auxiliary function operating in conjunction with the robotlink, in response to a sequence of link position commands and auxiliaryfunction commands read from a robot program memory; an auxiliaryfunction memory, associated with the controller, for temporarily storingauxiliary function commands; means for loading the auxiliary functionmemory with auxiliary function commands, prior to storing a sequence oflink position commands and auxiliary function commands in the robotprogram memory, so that the auxiliary function commands can be read fromthe auxiliary function memory in a desired order; means for producing asequence of robot link position commands; manually operated auxiliaryfunction command sequencing means for effecting the reading of eachauxiliary function command, in order, from the auxiliary function memoryat a point in the sequence of robot link position commands correlated tothe point during the sequence of robot link position commands at whichthe sequencing means is manually operated; and memory means in thecontroller, coupled to the means for producing link position commandsand to the auxiliary function memory, simulator and to the auxiliaryfunction memory, including a robot program memory for storing thesequence of link position commands produced by the simulator interleavedwith the auxiliary function commands read from the auxiliary functionmemory, each auxiliary function command being stored at a point in thesequence of robot link position commands correlated to the point in thesequence of robot link position commands at which the auxiliary functioncommand sequencing means is manually operated.
 14. The control system ofclaim 13 which further comprises means for implementing each auxiliaryfunction command as it is read from the auxiliary function memory forstorage in the robot program memory.
 15. The control system of claim 14which further comprises an auxiliary output device not associated withthe robot link and in which the means for implementing auxiliaryfunction commands includes means for providing an auxiliary outputcommand to the auxiliary output device to activate the device.
 16. Thecontrol system of claim 14 which further comprises an auxiliary inputdevice not associated with the robot link and in which the means forimplementing auxiliary function commands includes means for reading thecondition of the auxiliary input device in response to an auxiliaryinput function command read from the robot program memory.
 17. Thecontrol system of claim 15 which further comprises an auxiliary inputdevice not associated with the robot link and in which the means forimplementing auxiliary function commands includes means for reading thecondition of the auxiliary input device in response to an auxiliaryinput function command read from the robot program memory.
 18. Thecontrol system of claim 17 in which the controller drives a plurality ofarticulated robot links, which comprise a work robot, under closed loopservo control for movement relative to a work piece, and the auxiliaryoutput device includes means for varying the orientation of the workpiece relative to the work robot.
 19. A control system for a work robotwhich includes a spray coating gun for applying a spray coating to awork piece comprising:a controller for concurrently (a) driving at leastone articulated robot link under closed loop servo control, (b)executing at least one spray gun command in conjunction with the robotlink, and (c) executing at least one auxiliary function operating inconjunction with the robot link, in response to a sequence of linkposition commands, gun commands, and auxiliary function commands readfrom a robot program memory; an auxiliary function memory, associatedwith the controller, for temporarily storing auxiliary functioncommands; means for loading the auxiliary function memory with auxiliaryfunction commands, prior to storing a sequence of link position commandsand auxiliary function commands in the robot program memory, so that theauxiliary function commands can be read from the auxiliary functionmemory in a desired order; means for producing a sequence of robot linkposition commands; a robot simulator spray gun manually operable toproduce gun commands for controlling the flow of coating material fromthe gun; manually operated auxiliary function command sequencing meansfor effecting the reading of each auxiliary function command, in order,from the auxiliary function memory at a point in the sequence of robotlink position commands correlated to the point during the sequence ofrobot link position commands at which the sequencing means is manuallyoperated; and memory means in the controller, coupled to the means forproducing a sequence of robot link position commands, the simulatorspray gun, and the auxiliary function memory, including a robot programmemory for storing the sequence of link position commands produced bythe simulator interleaved with the gun commands and the auxiliaryfunction commands read from the auxiliary function memory, eachauxiliary function command being stored at a point in the sequence ofrobot link position commands correlated to the point in the sequence ofrobot link position commands at which the auxiliary function commandsequencing means is manually operated.
 20. The control system of claim19 which further comprises means for implementing each auxiliaryfunction command as it is read from the auxiliary function memory forstorage in the robot program memory.
 21. The control system of claim 20which further comprises an auxiliary output device not associated withthe robot link and in which the means for implementing auxiliaryfunction commands includes means for providing an auxiliary outputcommand to the auxiliary output device to activate the device.
 22. Thecontrol system of claim 20 which further comprises an auxiliary inputdevice not associated with the robot link and in which the means forimplementing auxiliary function commands includes means for reading thecondition of the auxiliary input device in response to an auxiliaryinput function command read from the robot program memory.
 23. Thecontrol system of claim 21 which further comprises an auxiliary inputdevice not associated with the robot link and in which the means forimplementing auxiliary function commands includes means for reading thecondition of the auxiliary input device in response to an auxiliaryinput function command read from the robot program memory.
 24. Thecontrol system of claim 23 in which the controller drives a plurality ofarticulated robot links, which comprise a work robot, under closed loopservo control for movement relative to a work piece, and the auxiliaryoutput device includes means for varying the orientation of the workpiece relative to the work robot.
 25. A method of storing a program forconcurrently (a) driving a work robot having at least one articulatedlink under closed loop servo control and (b) executing at least oneauxiliary function not related to the robot link, in which the programis made up of a sequence of link position commands interleaved withauxiliary function commands, comprising the steps of:loading anauxiliary function memory with auxiliary function commands so that thecommands can be read from the auxiliary function memory in a desiredorder; producing a sequence of robot link position commands; readingeach auxiliary function command from the auxiliary function memory, insequence, during the production of the robot link position commands; andstoring the sequence of link position commands interleaved with theauxiliary function commands read from the auxiliary function memory,with each auxiliary function command being stored at a point in thesequence of link position commands correlated to the point in the linkposition command sequence at which the auxiliary function command isread from the auxiliary function memory.
 26. The method of claim 25which includes the additional step, after the step of reading eachauxiliary function command from the auxiliary function memory, ofexecuting the auxiliary function called for by each auxiliary functioncommand.
 27. A method of storing a program for concurrently (a) drivinga work robot having at least one articulated link under closed loopservo control and (b) executing at least one auxiliary function notrelated to the robot link in which the program is made up of a sequenceof link position commands interleaved with auxiliary function commands,comprising the steps of:loading an auxiliary function memory withauxiliary function commands so that the commands can subsequently beread from the auxiliary function memory during a training session in adesired order; manually manipulating a robot simulator during thetraining session to produce a sequence of robot link position commands;manually operating an auxiliary function command sequence switch foreffecting the reading of each auxiliary function command, in order, fromthe auxiliary function memory during the training session; and storingthe sequence of link position commands produced by the manipulation ofthe robot simulator interleaved with the auxiliary function commandsread from the auxiliary function memory, with each auxiliary functioncommand being stored at a point in the sequence of link positioncommands correlated to the point in the link command sequence at whichthe sequence switch is manually operated.
 28. The method of claim 27which includes the additional step, after the step of manually operatingthe auxiliary function command sequence switch, of executing theauxiliary function called for by each auxiliary function command readfrom the auxiliary function memory, the point in the sequence of linkposition commands at which the auxiliary function is executed beingcorrelated to the point in the link command sequence at which theauxiliary function command sequence switch is manually operated.
 29. Amethod of storing a program for concurrently (a) driving a work robothaving a plurality of articulated links under closed loop servo controlto perform work upon a work piece and (b) executing a number ofauxiliary functions not related to the articulated robot links, in whichthe program is made up of a sequence of link position commands used tocontrol the articulated robot links interleaved with auxiliary functioncommands used to control the execution of the auxiliary functions,comprising the steps of:loading an auxiliary function memory withauxiliary function commands so that the commands can be read from theauxiliary function memory in a desired order during a training sessionin which the work robot program is stored; manually manipulating a robotsimulator made up of a plurality of articulated links corresponding tothose of the work robot to produce a sequence of robot link positioncommands during a training session; manually operating an auxiliaryfunction command sequence switch during the training session to effectthe reading of each auxiliary function command, in order, from theauxiliary function memory; executing the auxiliary function called forby each auxiliary function command read from the auxiliary functionmemory at a point in the sequence of link position commands correlatedto the point in the link command sequence at which the sequence switchis manually operated; and storing the sequence of link position commandsproduced by the simulator interleaved with the auxiliary functioncommands read from the auxiliary function memory to thereby store aprogram for the work robot, each auxiliary function command being storedat a point in the link position command sequence correlated to the pointin the link command sequence at which the sequence switch was manuallyoperated.
 30. The method of claim 29 in which the step of executing theauxiliary function called for by each auxiliary function command readfrom the auxiliary function memory comprises reading the condition of anauxiliary input from an auxiliary input device associated with the workpiece operated upon by the work robot.
 31. The method of claim 29 inwhich the step of executing the auxiliary function called for by eachauxiliary function command read from the auxiliary function memorycomprises producing an auxiliary function output signal for activatingan auxiliary output device associated with the work robot and the workpiece.
 32. The method of claim 31 in which the step of executing theauxiliary function called for by each auxiliary function command writtenfrom the auxiliary function memory comprises producing an auxiliaryfunction output signal for actuating an auxiliary output device to alterthe orientation of the work piece relative to the work robot.